.class Lcom/waiqin365/h5/customer/c;
.super Ljava/lang/Object;

# interfaces
.implements Ljava/lang/Runnable;


# instance fields
.field final synthetic a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;


# direct methods
.method constructor <init>(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)V
    .locals 0

    iput-object p1, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public run()V
    .locals 5

    const/4 v3, 0x0

    invoke-static {}, Lcom/waiqin365/lightapp/view/a/b;->a()Ljava/util/Observable;

    move-result-object v0

    iget-object v1, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-virtual {v0, v1}, Ljava/util/Observable;->addObserver(Ljava/util/Observer;)V

    new-instance v1, Landroid/content/Intent;

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v0}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->a(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Lorg/apache/cordova/WqCordovaActivity;

    move-result-object v0

    const-class v2, Lcom/waiqin365/lightapp/kehu/OfflineCmSelectMultiModeActivity;

    invoke-direct {v1, v0, v2}, Landroid/content/Intent;-><init>(Landroid/content/Context;Ljava/lang/Class;)V

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v0}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->b(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Lorg/apache/cordova/CordovaArgs;

    move-result-object v0

    if-eqz v0, :cond_2

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v0}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->b(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Lorg/apache/cordova/CordovaArgs;

    move-result-object v0

    invoke-virtual {v0, v3}, Lorg/apache/cordova/CordovaArgs;->isNull(I)Z

    move-result v0

    if-nez v0, :cond_2

    :try_start_0
    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v0}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->b(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Lorg/apache/cordova/CordovaArgs;

    move-result-object v0

    const/4 v2, 0x0

    invoke-virtual {v0, v2}, Lorg/apache/cordova/CordovaArgs;->getString(I)Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v2

    if-nez v2, :cond_2

    new-instance v2, Lorg/json/JSONObject;

    invoke-direct {v2, v0}, Lorg/json/JSONObject;-><init>(Ljava/lang/String;)V

    const-string/jumbo v0, "selectedIds"

    invoke-virtual {v2, v0}, Lorg/json/JSONObject;->has(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_4

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    const-string/jumbo v3, "selectedIds"

    invoke-virtual {v2, v3}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v3

    invoke-static {v0, v3}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->a(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;Ljava/lang/String;)Ljava/lang/String;

    :goto_0
    const-string/jumbo v0, "unEnableIds"

    invoke-virtual {v2, v0}, Lorg/json/JSONObject;->has(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_5

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    const-string/jumbo v3, "unEnableIds"

    invoke-virtual {v2, v3}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v3

    invoke-static {v0, v3}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->b(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;Ljava/lang/String;)Ljava/lang/String;

    :goto_1
    const-string/jumbo v0, "isOnline"

    invoke-virtual {v2, v0}, Lorg/json/JSONObject;->has(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    const-string/jumbo v3, "isOnline"

    invoke-virtual {v2, v3}, Lorg/json/JSONObject;->getBoolean(Ljava/lang/String;)Z

    move-result v3

    invoke-static {v0, v3}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->a(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;Z)Z

    :cond_0
    const-string/jumbo v0, "superTradeType"

    invoke-virtual {v2, v0}, Lorg/json/JSONObject;->has(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_1

    const-string/jumbo v0, "superTradeType"

    invoke-virtual {v2, v0}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-nez v0, :cond_1

    const-string/jumbo v0, "superTradeType"

    const-string/jumbo v3, "superTradeType"

    invoke-virtual {v2, v3}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v1, v0, v3}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    :cond_1
    const-string/jumbo v0, "tradeType"

    invoke-virtual {v2, v0}, Lorg/json/JSONObject;->has(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_2

    const-string/jumbo v0, "tradeType"

    invoke-virtual {v2, v0}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v2

    if-nez v2, :cond_2

    new-instance v2, Lorg/json/JSONObject;

    invoke-direct {v2}, Lorg/json/JSONObject;-><init>()V

    const-string/jumbo v3, "jsonStr"

    const-string/jumbo v4, "tradeType"

    invoke-virtual {v2, v4, v0}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    move-result-object v0

    invoke-virtual {v0}, Lorg/json/JSONObject;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v1, v3, v0}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;
    :try_end_0
    .catch Lorg/json/JSONException; {:try_start_0 .. :try_end_0} :catch_0

    :cond_2
    :goto_2
    const-string/jumbo v0, "jsonStr"

    new-instance v2, Ljava/lang/StringBuilder;

    invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V

    const-string/jumbo v3, "{\"customerIds\":\""

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    iget-object v3, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v3}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->c(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    const-string/jumbo v3, "\"}"

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v0, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    const-string/jumbo v0, "unableCheckIds"

    iget-object v2, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v2}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->d(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v0, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    const-string/jumbo v0, "returnTo"

    iget-object v2, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    iget-object v2, v2, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->a:Ljava/lang/String;

    invoke-virtual {v1, v0, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v0}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->e(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-nez v0, :cond_3

    const-string/jumbo v0, "isOnline"

    iget-object v2, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v2}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->f(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Z

    move-result v2

    invoke-virtual {v1, v0, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Z)Landroid/content/Intent;

    const-string/jumbo v0, "queryEmpId"

    iget-object v2, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v2}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->e(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v0, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    :cond_3
    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v0}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->a(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Lorg/apache/cordova/WqCordovaActivity;

    move-result-object v0

    invoke-virtual {v0, v1}, Lorg/apache/cordova/WqCordovaActivity;->startActivity(Landroid/content/Intent;)V

    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    invoke-static {v0}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->a(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;)Lorg/apache/cordova/WqCordovaActivity;

    move-result-object v0

    const v1, 0x7f040022

    const v2, 0x7f040021

    invoke-virtual {v0, v1, v2}, Lorg/apache/cordova/WqCordovaActivity;->overridePendingTransition(II)V

    return-void

    :cond_4
    :try_start_1
    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    const-string/jumbo v3, ""

    invoke-static {v0, v3}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->a(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;Ljava/lang/String;)Ljava/lang/String;
    :try_end_1
    .catch Lorg/json/JSONException; {:try_start_1 .. :try_end_1} :catch_0

    goto/16 :goto_0

    :catch_0
    move-exception v0

    invoke-virtual {v0}, Lorg/json/JSONException;->printStackTrace()V

    goto/16 :goto_2

    :cond_5
    :try_start_2
    iget-object v0, p0, Lcom/waiqin365/h5/customer/c;->a:Lcom/waiqin365/h5/customer/WqCustomerSelectMore;

    const-string/jumbo v3, ""

    invoke-static {v0, v3}, Lcom/waiqin365/h5/customer/WqCustomerSelectMore;->b(Lcom/waiqin365/h5/customer/WqCustomerSelectMore;Ljava/lang/String;)Ljava/lang/String;
    :try_end_2
    .catch Lorg/json/JSONException; {:try_start_2 .. :try_end_2} :catch_0

    goto/16 :goto_1
.end method
